import {Entity, PrimaryGeneratedColumn, Column, BaseEntity, CreateDateColumn} from "typeorm";

@Entity()
export class UserMsg extends BaseEntity{
  @PrimaryGeneratedColumn()
  id: string;
  
  @Column({default: ''})
  roomId: string;

  @Column({type: 'longtext'})
  msgText: string;

  msgType: string;
  
  @Column()
  formUserName: string;

  @Column({default: ''})
  toUserName: string;

  @CreateDateColumn({ type: 'timestamp' })
  createDate: Date;
}